<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8"/>
    <meta name="viewport"
          content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
    <title>sean 第三方授权</title>
    <link rel="stylesheet" type="text/css" th:href="@{/css/bootstrap.min.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{/css/signin.css}"/>
</head>

<body>
<nav class="navbar navbar-default container-fluid">
    <div class="container">
        <div class="navbar-header">
            <a class="navbar-brand" href="#">开放平台</a>
        </div>
        <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-5">
            <p class="navbar-text navbar-right">
                <a th:if="!${principalName}">未登录</a>
                <a th:if="${principalName}" target="_blank" th:text="${principalName}"></a>
            </p>
        </div>
    </div>
</nav>
<div style="padding-top: 80px;width: 300px; color: #555; margin: 0px auto;">
    <form id='confirmationForm' name='confirmationForm' th:action="@{/oauth2/authorize}" method='post'>
        <input type="hidden" name="client_id" th:value="${clientId}">
        <input type="hidden" name="state" th:value="${state}">
        <p>
            将获得以下权限：</p>
        <ul class="list-group">
            <li class="list-group-item" th:each="scopeMap:${scopeMap}">
                <input type="checkbox" th:checked="${scopeMap.value}" name="scope" th:value="${scopeMap.getKey()}" />
                <span th:text="${scopeMap.getKey()}"></span>
            </li>
        </ul>
        <p class="help-block">授权后表明你已同意 <a>服务协议</a></p>
        <button class="btn btn-success pull-right" type="submit" id="write-email-btn">授权</button>
    </form>
</div>
</body>
</html>
